<%-- 
    Document   : home
    Created on : Apr 11, 2013, 12:10:16 PM
    Author     : mona.chandrapal
--%>

<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Issue Tracker</title>

<script type="text/javascript" src="../jquery/jquery-1.7.2.min.js"></script>

<!-- Bootstrap -->
<link href="../twbootstrap/css/bootstrap.min.css" rel="stylesheet"
	media="screen">
<link href="../twbootstrap/css/bootstrap-responsive.min.css"
	rel="stylesheet" media="screen">
<script src="../twbootstrap/js/bootstrap.min.js"></script>
<script src="../twbootstrap/js/bootstrap-dropdown.js"></script>

<style>
.styleforborder {
	position: relative;
	margin: 5px, 5px, 5px, 5px;
	padding: 10px 10px 10px 10px;
	border: 1px solid #ddd;
	-webkit-border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-box-shadow: 1px 5px 10px #888;
	border-radius: 4px;
	width: 90%;
}

.mylist a {
	color: grey;
}

.mylist div:HOVER {
	color: black;
	background-color: #F8F8F8;
}

.sidebar-nav {
	padding: 9px 0;
	-webkit-box-shadow: 1px 5px 10px #888;
}
</style>



<script type="text/javascript" charset="utf-8">
	function PageInit() {
		//alert("PageLoad: ");
		$.ajax({
			type : "post",
			url : "../GetIssueDetail",
			datatype : "json",
			data : "issueid=0",
			success : function(data) {
				if (data.issuedetails.length > 0) {
					
					$("#issuelist").html("<ul>");
					var i;
					for (i = 0; i < data.issuedetails.length; i++) {
						
						var bugid="N.A.";
						
						if (data.issuedetails[i].bugid.length > 0) {
							bugid = data.issuedetails[i].bugid;
						} 
						
						
						$("#issuelist").append(
								"<li ><b>Issue: </b>"
										+ data.issuedetails[i].issuetitle + "<b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Bugid: </b>"+  bugid);
						
						$("#issuelist").append(
								"<b>Createdby: </b>"
										+ data.issuedetails[i].createdby);
						$("#issuelist").append("<br/>");
						$("#issuelist").append(
								"<b>Details: </b>"
										+ data.issuedetails[i].issuedetails.substring(0,200));
						$("#issuelist").append("</li> <hr>");

					}
					$("#issuelist").append("</ul>");

				}

			},
			error : function(jqXHR, textStatus) {
				alert("Error viewing article: " + textStatus);
			}
		});

	};
</script>


</head>

<body onload="PageInit()">
	<%@include file="header.jsp"%>


	<h3 align="center" style="color: #A1A1A1; font-style: italic;">
		Recently Added Issues</h3>


	<div  style="padding-left: 10%; padding-right: 10%">
		<div id="issuelist"></div>
	</div>

	<!-- 		<div class="mylist" align="center">
			<table style="width: 100%;">
				<tr>
					<td style="padding-bottom: 10px;" align="center"><a
						href="test.jsp" style="text-decoration: none"><div
								class="styleforborder" style="text-align: left">
								<span style="font-weight: bold; color: #335CD6;">Issue 1</span><br />
								Description of the issue
							</div></a></td>
				</tr>
				<tr>
					<td style="padding-bottom: 10px;" align="center"><a
						href="test.jsp" style="text-decoration: none"><div
								class="styleforborder" style="text-align: left">
								<h5>Issue 2</h5>
								Description of the issue
							</div></a></td>
				</tr>
				<tr>
					<td style="padding-bottom: 10px;" align="center"><a
						href="test.jsp" style="text-decoration: none"><div
								class="styleforborder" style="text-align: left">
								<h5>Issue 3</h5>
								Description of the issue
							</div></a></td>
				</tr>
			</table>
		</div>
		
		 -->
</body>
</html>
